Skip to main content

Selection Assistant

Note: The util is in an experimental state

ES6 Module Import​

import getElementSelection from "@ui5/webcomponents-base/dist/util/SelectionAssistant.js";

The sample demonstrates the usage of SelectionAssistant, which enhances user interactions by returning the coordinates of the selected text on the select event. This utility enables developers to create advanced AI-powered scenarios by easily capturing and utilizing the exact coordinates of user-selected text.

Input with Selection Assistant sample​

TextArea with Selection Assistant sample​